package com.demo.supplier.entity;

import com.baomidou.mybatisplus.annotation.*;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import java.io.Serializable;
import java.time.LocalDateTime;

/**
 * 文件信息实体
 *
 * @author demo
 * @since 2024-12-19
 */
@Data
@TableName("T_FILE_INFO")
@ApiModel(value = "FileInfo", description = "文件信息实体")
public class FileInfo implements Serializable {

    private static final long serialVersionUID = 1L;

    @ApiModelProperty("文件ID")
    @TableId(value = "ID", type = IdType.ASSIGN_ID)
    private Long id;

    @ApiModelProperty("原始文件名")
    @TableField("FILE_NAME")
    private String fileName;

    @ApiModelProperty("存储文件名")
    @TableField("STORAGE_NAME")
    private String storageName;

    @ApiModelProperty("文件路径")
    @TableField("FILE_PATH")
    private String filePath;

    @ApiModelProperty("文件类型")
    @TableField("FILE_TYPE")
    private String fileType;

    @ApiModelProperty("文件大小(字节)")
    @TableField("FILE_SIZE")
    private Long fileSize;

    @ApiModelProperty("MIME类型")
    @TableField("CONTENT_TYPE")
    private String contentType;

    @ApiModelProperty("文件MD5值")
    @TableField("FILE_MD5")
    private String fileMd5;

    @ApiModelProperty("状态：1=正常，0=删除")
    @TableField("STATUS")
    private Integer status;

    @ApiModelProperty("创建时间")
    @TableField(value = "CREATE_TIME", fill = FieldFill.INSERT)
    private LocalDateTime createTime;

    @ApiModelProperty("更新时间")
    @TableField(value = "UPDATE_TIME", fill = FieldFill.INSERT_UPDATE)
    private LocalDateTime updateTime;

    @ApiModelProperty("创建人")
    @TableField(value = "CREATE_BY", fill = FieldFill.INSERT)
    private Long createBy;

    @ApiModelProperty("更新人")
    @TableField(value = "UPDATE_BY", fill = FieldFill.INSERT_UPDATE)
    private Long updateBy;

    @ApiModelProperty("删除标记：1=已删除，0=未删除")
    @TableField("DELETED")
    @TableLogic
    private Integer deleted;
}